Ext.define('DCApp.view.relic.List', {
    extend: 'Ext.grid.Panel',
    alias: 'widget.reliclist',
    
    requires: [
        'DCApp.view.relic.ListController',
        'DCApp.view.relic.ListModel'
    ],

    controller: 'reliclist',
    plugins: ['gfilters'],
    viewModel: {
        type: 'reliclist'
    },
    bind: {
        store: '{relics}'
    },
    header:false,
    title: 'Array Grid',

    selType: 'checkboxmodel',
    
    tbar: ['->',{
        text: '录入',
        handler: 'onNew'
    }],
    
	bubbleEvents:['viewrelic','newrelic'],
	
	listeners: {
        itemdblclick: 'onRelicDblClick'
    },
    
    columns: [
		{
            text     : '文物ID',
            dataIndex: 'objId',
            filter: 'number'
        },
        {
            text     : '作者(窑口)',
            dataIndex: 'objAuthor',
            filter: 'string'
        },
        {
            text     : '分类',
            dataIndex: 'classa',
            filter: 'string'
        },
        {
            text     : '文物编号',
            dataIndex: 'objNo',
            filter: 'string'
        },
        {
            text     : '文物名称',
            dataIndex: 'objName',
            filter: 'string'
        },
        {
            text     : '级别',
            dataIndex: 'grade',
            filter: 'string'
        },
        {
            text     : '正文字数',
            dataIndex: 'objNumber',
            filter: 'number'
        },
        {
            text     : '撰稿人',
            dataIndex: 'author',
            filter: 'string'
        }
    ],
    
    initComponent: function(){    	
    	 this.callParent();
    }
 });
